using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._DataManagementTools._LayersandTableViews
{
    /// <summary>
    /// <para>Make Raster Layer</para>
    /// <para>Creates a raster layer from an input raster dataset or layer file. The layer created by the tool is temporary and will not persist after the session ends unless the layer is saved to disk or the map document is saved.</para>
    /// <para>根据输入栅格数据集或图层文件创建栅格图层。该工具创建的图层是临时的，除非将图层保存到磁盘或保存地图文档，否则会话结束后不会保留。</para>
    /// </summary>    
    [DisplayName("Make Raster Layer")]
    public class MakeRasterLayer : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public MakeRasterLayer()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_raster">
        /// <para>Input raster</para>
        /// <para><xdoc>
        ///   <para>The path and name of the input raster dataset.</para>
        ///   <para>You can use a raster layer from a GeoPackage as the input. To reference a raster within a GeoPackage, type the name of the path, followed by the name of the GeoPackage and the name of the raster. For example, c:\data\sample.gpkg\raster_tile would be your input raster, where sample.gpkg is the name of the GeoPackage and raster_tile is the raster dataset within the package.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>输入栅格数据集的路径和名称。</para>
        ///   <para>您可以使用 GeoPackage 中的栅格图层作为输入。要引用 GeoPackage 中的栅格，请输入路径的名称，后跟 GeoPackage 的名称和栅格的名称。例如，c：\data\sample.gpkg\raster_tile 为输入栅格，其中 sample.gpkg 是 GeoPackage 的名称，raster_tile 是包中的栅格数据集。</para>
        /// </xdoc></para>
        /// </param>
        /// <param name="_out_rasterlayer">
        /// <para>Output raster layer name</para>
        /// <para>The name of the layer to create.</para>
        /// <para>要创建的图层的名称。</para>
        /// </param>
        public MakeRasterLayer(object _in_raster, object _out_rasterlayer)
        {
            this._in_raster = _in_raster;
            this._out_rasterlayer = _out_rasterlayer;
        }
        public override string ToolboxName => "Data Management Tools";

        public override string ToolName => "Make Raster Layer";

        public override string CallName => "management.MakeRasterLayer";

        public override List<string> AcceptEnvironments => ["scratchWorkspace", "workspace"];

        public override object[] ParameterInfo => [_in_raster, _out_rasterlayer, _where_clause, _envelope, _band_index];

        /// <summary>
        /// <para>Input raster</para>
        /// <para><xdoc>
        ///   <para>The path and name of the input raster dataset.</para>
        ///   <para>You can use a raster layer from a GeoPackage as the input. To reference a raster within a GeoPackage, type the name of the path, followed by the name of the GeoPackage and the name of the raster. For example, c:\data\sample.gpkg\raster_tile would be your input raster, where sample.gpkg is the name of the GeoPackage and raster_tile is the raster dataset within the package.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>输入栅格数据集的路径和名称。</para>
        ///   <para>您可以使用 GeoPackage 中的栅格图层作为输入。要引用 GeoPackage 中的栅格，请输入路径的名称，后跟 GeoPackage 的名称和栅格的名称。例如，c：\data\sample.gpkg\raster_tile 为输入栅格，其中 sample.gpkg 是 GeoPackage 的名称，raster_tile 是包中的栅格数据集。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input raster")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_raster { get; set; }


        /// <summary>
        /// <para>Output raster layer name</para>
        /// <para>The name of the layer to create.</para>
        /// <para>要创建的图层的名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output raster layer name")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_rasterlayer { get; set; }


        /// <summary>
        /// <para>Where clause</para>
        /// <para>Using SQL, you can define a query or use the Query Builder to build a query.</para>
        /// <para>使用 SQL，可以定义查询或使用查询生成器生成查询。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Where clause")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _where_clause { get; set; } = null;


        /// <summary>
        /// <para>Envelope</para>
        /// <para><xdoc>
        ///   <para>The output extent can be specified by defining the four coordinates or by using the extent of an existing layer.</para>
        ///   <bulletList>
        ///     <bullet_item>Default—The extent will be based on the maximum extent of all participating inputs. This is the default.</bullet_item><para/>
        ///     <bullet_item>Current Display Extent—The extent is equal to the data frame or visible display. The option is not available when there is no active map.</bullet_item><para/>
        ///     <bullet_item>As Specified Below—The extent will be based on the minimum and maximum extent values specified.</bullet_item><para/>
        ///     <bullet_item>Browse—The extent will be based on an existing dataset.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>可以通过定义四个坐标或使用现有图层的范围来指定输出范围。</para>
        ///   <bulletList>
        ///     <bullet_item>默认值 - 范围将基于所有参与输入的最大范围。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>当前显示范围 - 范围等于数据框或可见显示。当没有活动地图时，该选项不可用。</bullet_item><para/>
        ///     <bullet_item>如下所述 - 范围将基于指定的最小和最大范围值。</bullet_item><para/>
        ///     <bullet_item>浏览 - 范围将基于现有数据集。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Envelope")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _envelope { get; set; } = null;


        /// <summary>
        /// <para>Bands</para>
        /// <para>Choose which bands to export for the layer. If no bands are specified, all the bands will be used in the output.</para>
        /// <para>选择要为图层导出的波段。如果未指定波段，则将在输出中使用所有波段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Bands")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _band_index { get; set; } = null;


        public MakeRasterLayer SetEnv(object scratchWorkspace = null, object workspace = null)
        {
            base.SetEnv(scratchWorkspace: scratchWorkspace, workspace: workspace);
            return this;
        }

    }

}